div.mod-deploy.deploy-detail
	div.detail-header
		.detail-item
			em.item-name 所在集群
			b.item-content(ng-bind="config.clusterName")
		i.detail-sep
		.detail-item
			em.item-name namespace
			b.item-content(ng-bind="config.namespace")
		i.detail-sep
		.detail-item
			em.item-name 上次升级时间
			b.item-content(ng-bind="vmDome.parseDate(config.lastUpdateTime)")
		i.detail-sep
		.detail-item
			em.item-name 实例个数
			b.item-content(ng-bind="config.currentReplicas")
		i.detail-sep
		.detail-item
			em.item-name 当前版本
			b.item-content(ng-if="!config.currentVersions||config.currentVersions.length===0") 无
			b.item-content(ng-repeat="version in config.currentVersions" ng-cloak) version{{version.version}}
		i.detail-sep
		.detail-item
			em.item-name 状态
			b.item-content(ng-switch="config.deploymentStatus")
				span.txt-success(ng-switch-when="RUNNING") 运行中
				span.txt-error(ng-switch-when="STOP") 停止
				span.txt-primary(ng-switch-when="DEPLOYING") 部署中
				span.txt-warning(ng-switch-when="ERROR") 异常
				//- span.txt-default(ng-switch-when="AB_TEST") 灰度发布
				span.txt-primary(ng-switch-when="STOPPING") 停止中
				span.txt-primary(ng-switch-when="UPDATING") 升级中
				span.txt-primary(ng-switch-when="BACKROLLING") 回滚中
				span.txt-primary(ng-switch-when="UPSCALING") 扩容中
				span.txt-primary(ng-switch-when="DOWNSCALING") 缩容中
				span.txt-warning(ng-switch-when="ABORTING") 中断中
				span.txt-warning(ng-switch-when="BACKROLL_ABORTED") 回滚已中断
				span.txt-warning(ng-switch-when="UPDATE_ABORTED") 升级已中断
		.deploy-option.pull-right(ng-switch="config.deploymentStatus")
			span(ng-switch-when="RUNNING")
				button.ui-btn.ui-btn-bright.ui-btn-md(ng-disabled="isWaitingUpVersion" ng-click="updateVersion()" ng-if="!config.stateful") 升级/回滚
				button.ui-btn.ui-btn-bright.ui-btn-md(ng-disabled="isWaitingScale" ng-click="scaleVersion()" ng-if="!config.stateful") 扩容/缩容
				button.ui-btn.ui-btn-bright.ui-btn-md(ng-disabled="isWaitingStop" ng-click="stopVersion()") 停止
			//- button.ui-btn.ui-btn-bright.ui-btn-md(ng-switch-when="AB_TEST" ng-if="!config.stateful") 全部升级
			//- button.ui-btn.ui-btn-bright.ui-btn-md(ng-switch-when="AB_TEST" ng-if="!config.stateful") 全部回滚
			span(ng-switch-when="STOP")
				button.ui-btn.ui-btn-bright.ui-btn-md(ng-disabled="isWaitingStart" ng-click="startVersion()") 启动
				button.ui-btn.ui-btn-bright.ui-btn-md(ng-click="deleteDeploy()") 删除
			span(ng-if="config.deploymentStatus=='ERROR'||config.deploymentStatus=='BACKROLL_ABORTED'||config.deploymentStatus=='UPDATE_ABORTED'")
				button.ui-btn.ui-btn-bright.ui-btn-md(ng-if="!config.stateful" ng-disabled="isWaitingRecover" ng-click="recover()") 恢复
				button.ui-btn.ui-btn-bright.ui-btn-md(ng-disabled="isWaitingStop" ng-click="stopVersion()") 停止
			button.ui-btn.ui-btn-bright.ui-btn-md(ng-switch-when="DEPLOYING" ng-disabled="isWaitingOperation" ng-click="abortDeploy('DEPLOYING')") 中断启动
			button.ui-btn.ui-btn-bright.ui-btn-md(ng-switch-when="UPDATING" ng-disabled="isWaitingOperation" ng-click="abortDeploy('UPDATING')") 中断升级
			button.ui-btn.ui-btn-bright.ui-btn-md(ng-switch-when="BACKROLLING" ng-disabled="isWaitingOperation" ng-click="abortDeploy('BACKROLLING')") 中断回滚
			button.ui-btn.ui-btn-bright.ui-btn-md(ng-switch-when="UPSCALING" ng-disabled="isWaitingOperation" ng-click="abortDeploy('UPSCALING')") 中断扩容
			button.ui-btn.ui-btn-bright.ui-btn-md(ng-switch-when="DOWNSCALING" ng-disabled="isWaitingOperation" ng-click="abortDeploy('DOWNSCALING')") 中断缩容
	loading(ng-if="isLoading=(loadingsIns.isLoading||(tabActive[0].active&&deployIns.loadingIns.isLoading)||(tabActive[1].active&&deployEditIns.loadingIns.isLoading))")
	tabset
		tab(heading="部署详情" active="tabActive[0].active" ui-sref="deployDetail.detail")
			.deploy-info
				.deploy-rollback
					span(ng-if="!config.stateful") 部署版本：
					span(ng-if="config.stateful") 该部署是有状态服务，只有一个部署版本：
					.com-select-con(select-con)
						button.ui-btn.ui-btn-select.ui-btn-white
							i.icon-down
							| {{deployIns.config.version?'version'+deployIns.config.version:'选择版本'}}
						ul.select-list
							li.select-item(ng-repeat="version in deployIns.versionList")
								a(ng-click="toggleVersion(version.version)" ng-cloak) version{{version.version}}
					//- button.ui-btn.ui-btn-primary.ui-btn-sm(ng-click="deployVersion()" ng-disabled="waitingForDeploy") 部署该版本
				ul.com-list-info.mirror-con(ng-repeat="containerDraft in config.containerDrafts" ng-show="config.version")
					li
						span.info-name 镜像名称
						.info-content
							span.first-info(ng-bind="containerDraft.image" style="font-weight:bold;")
					li(ng-if="config.stateful")
						span.info-name 镜像仓库
						.info-content
							span.first-info(ng-bind="containerDraft.registry")
					li
						span.info-name 镜像版本
						.info-content
							span.first-info(ng-bind="containerDraft.tag")
					li
						span.info-name 运行过程环境变量
						.info-content
							.line-long
								span.first-info(ng-if="!containerDraft.oldEnv||(containerDraft.oldEnv.length===0&&containerDraft.newEnv.length===0)") 未设置
								table.ui-table-primary.ui-table-env(ng-hide="!containerDraft.oldEnv||(containerDraft.oldEnv.length===0&&containerDraft.newEnv.length===0)")
									thead
										tr
											th 环境变量名
											th 环境变量值
											th 描述
									tbody
										tr(ng-repeat="env in containerDraft.oldEnv")
											td(ng-bind="env.key")
											td(ng-bind="env.value")
											td(ng-bind="env.description")
										tr(ng-repeat="env in containerDraft.newEnv")
											td(ng-bind="env.key")
											td(ng-bind="env.value")
											td(ng-cloak) {{env.description||'无'}}
					li
						span.info-name 容器大小
						.info-content(ng-cloak)
							.first-info
								span.small-info CPU：{{containerDraft.cpu}}个
								span.small-info 内存：{{containerDraft.mem}}MB
					li
						span.info-name 健康检查
						.info-content.first-info(ng-switch="containerDraft.healthChecker.type")
							span(ng-switch-default) None
							span(ng-switch-when="HTTP") HTTP检查
							span(ng-switch-when="TCP") TCP检查
							.health-info(ng-if="containerDraft.healthChecker.type=='TCP'||containerDraft.healthChecker.type=='HTTP'")
								span 检查端口:
								span.tool-next(ng-bind="containerDraft.healthChecker.port")
							.health-info(ng-if="containerDraft.healthChecker.type=='TCP'||containerDraft.healthChecker.type=='HTTP'")
								span 超时时间（s）:
								span.tool-next(ng-cloak) {{containerDraft.healthChecker.timeout}}
							.health-info(ng-if="containerDraft.healthChecker.type=='TCP'||containerDraft.healthChecker.type=='HTTP'")
								span 首次检测延迟（s）:
								span.tool-next(ng-cloak) {{containerDraft.healthChecker.delay}}
							.health-info(ng-if="containerDraft.healthChecker.type=='HTTP'")
								span 检测URL:
								span.tool-next(ng-bind="containerDraft.healthChecker.url")
							.health-info(ng-if="containerDraft.healthChecker.type=='HTTP'")
								span 允许返回值:
								span.tool-next 200-400(不包含400)
				h4.mod-title.txt-bright 部署设置
				ul.com-list-info
					li(ng-if="config.stateful")
						span.info-name 网络模式
						.info-content(ng-switch="config.networkMode")
							span.first-info(ng-switch-when="HOST") Host
							span.first-info(ng-switch-default) 默认
					li
						span.info-name(style="padding-top:8px;") 筛选主机
						.info-content
							div(ng-cloak)
								span 集群：{{deployIns.clusterListIns.cluster.name}}
								span.tool-next 部署环境：{{deployIns.envText}}
							.line-long(ng-if="config.stateful")
								span.tool-align-input 所选主机：
								.host-txt-con.line-element.com-select-con(select-con)
									ul.selected-labels
										li.select-label(ng-repeat="host in config.hostList" ng-bind="host")
							.line-long(ng-if="!config.stateful")
								span.tool-align-input 主机标签：
								.host-txt-con.line-element.com-select-con(select-con)
									ul.selected-labels
										li.select-label(ng-repeat="(label,value) in deployIns.nodeListIns.labelsInfo|search:'isSelected':true|search:'isShow':true" ng-cloak)
											| {{label}}
								span.txt-wrap
									a.link-safe(ng-click="deployIns.nodeListIns.showHost()") 查看选中主机
					li
						span.info-name 日志
						.info-content
							span.first-info(ng-if="config.logDraft.logItemDrafts.length===1") 未设置
							ul.log-info.first-info(ng-cloak)
								li(ng-repeat="logDraft in config.logDraft.logItemDrafts" ng-hide="$last")
									span.log-path 日志路径:{{logDraft.logPath}}
									span 自动收集日志:{{logDraft.autoCollect?'开启':'未开启'}}
									span(ng-if="logDraft.autoCollect")
										span 日志Topic：{{logDraft.logTopic}}
										span 预处理命令：{{logDraft.processCmd||'未设置'}}
											a.icon-help(style="margin-left:10px;" popover="对收集到的日志做进一步处理，比如筛选或增减字段等，可以用grep和awk命令完成，命令以管道形式执行，因此必须以“|”开始，比如一个典型的处理命令为：   | grep \"ERROR\\\\|WARN\\\\| EXCEPTION\\\\| statistic\" | awk -vnhost=\"$HOSTNAME\" '{print \"[\"nhost\"]--\"$0}'，该命令将只筛选包含四个对应关键字的行，并且会在行首添加\"[hostname]--\"的字符串，参照可完成其他复杂的处理方式")
									span 自动删除日志:{{logDraft.autoDelete?'开启':'未开启'}}
									span(ng-if="logDraft.autoDelete") 过期时间：{{logDraft.logExpired}}小时
					li
						span.info-name 网络模式
						.info-content
							div(ng-cloak)
								span.small-info {{showdeploy.networkMode=='HOST'?'Host':'Overlay'}}
		tab(heading="升级" active="tabActive[1].active" ng-if="!config.stateful" ui-sref="deployDetail.update")
			.deploy-info(ng-form role="form" name="deployForm" ng-class="{'need-valid':valid.needValid}")
				.mod-title 镜像设置
				.com-select-con.add-mirror(select-con)
					input.ui-input-white.ui-btn-select(placeholder="添加镜像" ng-model="imageKey")
					ul.select-list
						li.select-item(ng-repeat="image in deployEditIns.imageList|filter:{'imageName':imageKey}")
							a(ng-click="deployEditIns.addImage(image);imageKey=''")
								| {{image.imageName}}
								span.txt-prompt.pull-right {{image.registry}}
				a.link-safe.add-other(ng-click="deployEditIns.addOtherImage()") 添加其他镜像
				ul.com-list-info.mirror-con.mirror-collapse(ng-repeat="containerDraft in editConfig.containerDrafts" ng-form name="childForm" mirror-collapse)
					li.cancel
						a.icon-cancel(ng-click="deployEditIns.deleteImage($index)")
					li.down(ng-click="toggleCollapse()")
						i.icon-down-double(ng-class="{'up':!isCollapse}")
					li
						span.info-name 镜像版本
						.info-content
							span.first-info(ng-bind="containerDraft.registry")
					li
						span.info-name 镜像名称
						.info-content
							span.first-info.txt-bright(ng-bind="containerDraft.image" style="font-weight:bold;")
					li
						span.info-name 镜像版本
						.info-content
							.line-short.com-select-con(select-con)
								button.ui-btn.ui-btn-white.ui-btn-select(ng-cloak)
									i.icon-down
									| {{containerDraft.tag}}
								ul.select-list
									li(ng-if="!containerDraft.tagList||containerDraft.tagList.length===0")
										a 无版本信息
									li.select-item(ng-repeat="tag in containerDraft.tagList")
										a(ng-click="deployEditIns.toggleImageTag($parent.$index,tag.tag)")
											span.txt-prompt.image-tag(ng-bind="vmDome.parseDate(tag.createTime)")
											span(ng-bind="tag.tag")
					li(ng-show="!isCollapse")
						span.info-name 运行过程环境变量
						.info-content
							.line-long
								table.ui-table-primary.ui-table-env(ng-show="containerDraft.oldEnv.length!==0")
									thead
										tr
											th 环境变量名
											th 环境变量值
											th 描述
									tbody
										tr(ng-repeat="env in containerDraft.oldEnv")
											td(ng-bind="env.key")
											th.txt-cell
												input.ui-input-fill(ng-model="env.value" placeholder="环境变量值")
											td(ng-bind="env.description")
							.line-long.new-env-list(ng-repeat="env in containerDraft.newEnv")
								input.ui-input-fill.line-element(ng-model="env.key" placeholder="环境变量名" is-required param1="env.value" ng-pattern="/^[A-Za-z_][A-Za-z0-9_]*$/" )
								input.ui-input-fill.line-element(ng-model="env.value" placeholder="环境变量值" is-required param1="env.key")
								input.ui-input-fill.line-element(ng-model="env.description" placeholder="描述20字以内")
								span.txt-wrap
									a.icon-delete(ng-click="deployEditIns.deleteImageEnv($parent.$index,$index)")
							.line-long.new-env-list
								span.add-env(ng-click="deployEditIns.addImageEnv($index)")
									i.icon-add
					li(ng-show="!isCollapse")
						span.info-name 容器大小
						.info-content
							| CPU（个）
							input.ui-input-fill.ui-input-sm(ng-model="containerDraft.cpu" name="cpu" ng-pattern="/^(\\d*\\.)?\\d+$/" required)
							| 内存（MB）
							input.ui-input-fill.ui-input-sm(ng-model="containerDraft.mem" name="mem" ng-pattern="/^(\\d*\\.)?\\d+$/" required)
							span.tool-inline-error(ng-if="(valid.needValid||childForm.cpu.$dirty)&&childForm.cpu.$invalid||(valid.needValid||childForm.mem.$dirty)&&childForm.mem.$invalid") 请填写数字
					li(ng-show="!isCollapse")
						span.info-name.tool-align-input 健康检查
						.info-content
							dome-radio.com-check-con(d-id="{{'checkNONE_'+$index}}" d-value="'NONE'" d-name="healthCheckerType{{$index}}" d-label="None" d-model="containerDraft.healthChecker.type")
							dome-radio.com-check-con(d-id="{{'checkTCP_'+$index}}" d-value="'TCP'" d-name="healthCheckerType{{$index}}" d-disabled="{{editConfig.networkMode=='HOST'}}" d-label="TCP检查" d-model="containerDraft.healthChecker.type")
							dome-radio.com-check-con(d-id="{{'checkHTTP_'+$index}}" d-value="'HTTP'" d-name="healthCheckerType{{$index}}" d-disabled="{{editConfig.networkMode=='HOST'}}" d-label="HTTP检查" d-model="containerDraft.healthChecker.type")
							p.txt-prompt(ng-if="editConfig.networkMode=='HOST'") Host网络模式下不能使用健康检查
							.line-long(ng-if="containerDraft.healthChecker.type=='TCP'||containerDraft.healthChecker.type=='HTTP'")
								span.child-name 检查端口
								input.ui-input-fill.line-element(placeholder="请输入端口号" name="port" ng-model="containerDraft.healthChecker.port" required)
							span.child-error.txt-error(ng-if="(valid.needValid||childForm.port.$dirty)&&childForm.port.$invalid") 必填
							.line-long(ng-if="containerDraft.healthChecker.type=='TCP'||containerDraft.healthChecker.type=='HTTP'")
								span.child-name 超时时间（s）
								input.ui-input-fill.line-element(placeholder="超过时间达到规定阈值，则健康检查判定为异常" name="timeout" ng-model="containerDraft.healthChecker.timeout" required ng-pattern="/^[1-9]\\d*$/")
							span.child-error.txt-error(ng-if="(valid.needValid||childForm.timeout.$dirty)&&childForm.timeout.$invalid") 请填写数字
							.line-long(ng-if="containerDraft.healthChecker.type=='TCP'||containerDraft.healthChecker.type=='HTTP'")
								span.child-name 首次检测延迟（s）
								input.ui-input-fill.line-element(placeholder="容器启动后延迟规定秒数，再开始健康检查" name="delay" ng-model="containerDraft.healthChecker.delay" required ng-pattern="/^[1-9]\\d*$/")
							span.child-error.txt-error(ng-if="(valid.needValid||childForm.delay.$dirty)&&childForm.delay.$invalid") 请填写数字
							.line-long(ng-if="containerDraft.healthChecker.type=='HTTP'")
								span.child-name 检测URL
								input.ui-input-fill.line-element(placeholder="请输入URL" name="url" ng-model="containerDraft.healthChecker.url" required)
							span.child-error.txt-error(ng-if="(valid.needValid||childForm.url.$dirty)&&childForm.url.$invalid") 必填
							.line-long(ng-if="containerDraft.healthChecker.type=='HTTP'")
								span.child-name 允许返回值
								span.child-txt  200-400(不包含400)
				.mod-title.txt-bright 部署设置
				ul.com-list-info
					li
						span.info-name 筛选主机
						.info-content
							.line-short
								.com-select-con.line-element(select-con)
									button.ui-btn.ui-btn-white.ui-btn-select(disabled="true")
										i.icon-down
										| {{deployEditIns.clusterListIns.cluster.name}}
								.com-select-con.line-element.tool-next(select-con)
									button.ui-btn.ui-btn-white.ui-btn-select(ng-cloak disabled="true")
										i.icon-down
										| {{deployEditIns.envText}}
									input(type="hidden" ng-model="editConfig.hostEnv" name="hostEnv" required)
									span.txt-error(ng-if="(valid.needValid||deployForm.hostEnv.$dirty)&&deployForm.hostEnv.$invalid") 请选择部署环境
							.line-long
								.ui-input-white.host-txt-con.com-select-con(label="true" select-con)
									ul.selected-labels
										li.select-label(ng-repeat="(label,value) in deployEditIns.nodeListIns.labelsInfo|search:'isSelected':true|search:'isShow':true" ng-cloak)
											| {{label}}
											a.icon-cancel(ng-click="deployEditIns.nodeListIns.toggleLabel(label,false)")
										li.select-input
											input.line-element.ui-btn-select(placeholder="选择主机标签" ng-model="labelKey.key" ng-keydown="labelKeyDown($event,labelKey.key,labelsInfoFiltered)")
									ul.select-list
										li(ng-if="vmDome.objLength(labelsInfoFiltered)===0")
											a 无相关信息
										li.select-item(ng-repeat="(label,value) in labelsInfoFiltered=(deployEditIns.nodeListIns.labelsInfo | searchKey:labelKey.key|search:'isShow':true)")
											a(ng-bind="label" ng-click="deployEditIns.nodeListIns.toggleLabel(label,true);labelKey.key='';")
								span.txt-wrap
									a.link-safe(ng-click="deployEditIns.nodeListIns.showHost()") 查看选中主机
					li
						span.info-name 日志
						.info-content
							p.txt-prompt.no-log(ng-if="!deployIns.logConfig") 所选集群没有开启日志自动收集。不能进行日志相关配置。
							button.ui-btn.ui-btn-sm.ui-btn-active.add-log(ng-click="deployEditIns.addLogDraft()" ng-if="deployIns.logConfig") 添加
							div.log-item(ng-form ng-repeat="log in editConfig.logDraft.logItemDrafts" name="childForm" ng-if="deployIns.logConfig")
								a.icon-cancel.cancel-log(ng-click="deployEditIns.deleteLogDraft($index)")
								input.ui-input-fill.element-full(placeholder="请输入日志路径，不能放在根目录下"  ng-pattern="/^\/.*[^\/]$/" ng-model="log.logPath" name="logPath" is-required param1="{{log.autoCollect&&log.logTopic}}" param2="{{log.autoCollect&&log.processCmd}}" param3="{{log.autoDelete&&log.logExpired}}")
								span.txt-error(ng-if="childForm.logPath.$dirty&&childForm.logPath.$error.pattern") 非法的格式
								div.log-check
									input.ui-check(id="autoCollect{{$index}}" type="checkbox" name="autoCollect" ng-model="log.autoCollect")
									label(for="autoCollect{{$index}}") 自动收集日志
								.line-full(ng-if="log.autoCollect")
									span.log-title  日志topic
									input.ui-input-fill.line-element(placeholder="请输入日志topic" name="logTopic" ng-model="log.logTopic" required)
								.line-full(ng-if="log.autoCollect")
									span.log-title  预处理命令
									.line-element
										input.ui-input-fill.full(placeholder="请输入预处理命令" name="processCmd" ng-model="log.processCmd")
										span.txt-wrap
											a.icon-help(popover="对收集到的日志做进一步处理，比如筛选或增减字段等，可以用grep和awk命令完成，命令以管道形式执行，因此必须以“|”开始，比如一个典型的处理命令为：   | grep \"ERROR\\\\|WARN\\\\| EXCEPTION\\\\| statistic\" | awk -vnhost=\"$HOSTNAME\" '{print \"[\"nhost\"]--\"$0}'，该命令将只筛选包含四个对应关键字的行，并且会在行首添加\"[hostname]--\"的字符串，参照可完成其他复杂的处理方式")
								div.log-check
									input.ui-check(id="autoDelete{{$index}}" type="checkbox" name="autoDelete" ng-model="log.autoDelete")
									label(for="autoDelete{{$index}}") 自动删除日志
								.line-full(ng-if="log.autoDelete")
									span.log-title  过期时间
									input.ui-input-fill(placeholder="过期则自动删除" name="logExpired" ng-model="log.logExpired" required ng-pattern="/^[1-9]\\d*$/" )
									span.unit 小时
								.txt-error.log-error(ng-if="(valid.needValid||deployForm.logExpired.$dirty)&&deployForm.logExpired.$invalid") 请输入大于0的整数
					li
						span.info-name 网络模式
						.info-content
							span.first-info {{showdeploy.networkMode=='HOST'?'Host':'Overlay'}}

				.com-bottom-option
					span.span.com-bottom-option-con
						button.ui-btn.ui-btn-md.ui-btn-bright(ng-disabled="isWaitingUpdate||isLoading" ng-click="valid.needValid=true;deployForm.$valid&&toUpdate();") 保存升级设置
						.txt-error(ng-show="valid.needValid&&deployForm.$invalid") 存在不合法数据，请修改后提交。
		tab(heading="事件" active="tabActive[2].active" ng-click="getEvents()" ui-sref="deployDetail.event")
			.events-con
				ul.events-list
					li.event-success(ng-if="eventList.length===0") 无事件信息
					li(ng-repeat="event in eventList" ng-class="{'START':'event-building','PROCESSING':'event-building','SUCCESS':'event-success','FAILED':'event-failed','KUBERNETES':'event-system','ABORTED':'event-system'}[event.eventStatus]")
						span.icon-dot
							i.dot-line
						span.event-name(ng-bind="event.optTxt")
						span.event-result(ng-bind="event.statusTxt")
						span.event-date(ng-bind="event.date")
						span.event-author(ng-cloak)
							i.icon-user(tooltip="操作者")
							| {{event.userName}}
						span.event-process(ng-if="event.operation!='KUBERNETES'")
							span.event-process-item(tooltip="起始状态" tooltip-placement="left")
								i.icon-process-dot.start
								div.event-process-detail
									span.sig-event-process(ng-repeat="status in event.primarySnapshot" ng-bind="status.version+' , '+status.replicas")
							span.event-process-item(tooltip="目标状态" tooltip-placement="left")
								i.icon-process-dot.origin
								div.event-process-detail
									span.sig-event-process(ng-repeat="status in event.targetSnapshot" ng-bind="status.version+' , '+status.replicas")
							span.event-process-item(tooltip="完成状态" tooltip-placement="left")
								i.icon-process-dot.current
								div.event-process-detail
									span.sig-event-process(ng-repeat="status in event.currentSnapshot" ng-bind="status.version+' , '+status.replicas")
						span.event-process.tool-nowrap(ng-if="event.operation=='KUBERNETES'" ng-bind="event.message" popover="{{event.message}}" popover-trigger="mouseenter")
						span.txt-warning.event-info(ng-show="event.eventStatus=='FAILED'" popover="{{event.message}}" popover-trigger="mouseenter") 错误信息
		tab(heading="实例" active="tabActive[3].active" ui-sref="deployDetail.instance")
			.instance-con
				table.ui-table-dome.instance-list
					thead
						tr
							th 实例名称
							th 所在主机
							th 部署版本
							th 启动时间
							th 日志
							th 容器控制台
					tbody
						tr(ng-if="instanceList.length===0")
							td(colspan="6") 无实例信息
						tr(ng-repeat="ins in instanceList")
							td(ng-bind="ins.instanceName")
							td(ng-bind="ins.hostIp")
							td(ng-cloak) version{{ins.versionId}}
							td(ng-bind="vmDome.parseDate(ins.startTime)")
							td
								a.link-safe(ng-click="showLog(ins.instanceName,ins.containers)") 查看
							td
								a.link-safe(ng-click="toConsole($index)") 进入
		//- tab(heading="健康检查" active="tabActive[4].active" ui-sref="deployDetail.healthcheck")
			.health-con
				ul.com-list-info
					li
						span.info-name.not-align-input 健康检查
						.info-content(ng-switch="config.healthCheckerDraft.type")
							span(ng-switch-default) None
							span(ng-switch-when="HTTP") Http检查
							span(ng-switch-when="TCP") Tcp检查
							.line-long(ng-if="config.healthCheckerDraft.type=='TCP'||config.healthCheckerDraft.type=='HTTP'")
								span.child-name 检查端口
								span.child-txt(ng-bind="config.healthCheckerDraft.port")
							.line-long(ng-if="config.healthCheckerDraft.type=='TCP'||config.healthCheckerDraft.type=='HTTP'")
								span.child-name 超时时间（s）
								span.child-txt(ng-cloak) {{config.healthCheckerDraft.timeout}}
							.line-long(ng-if="config.healthCheckerDraft.type=='HTTP'")
								span.child-name 检测URL
								span.child-txt(ng-bind="config.healthCheckerDraft.url")
							.line-long(ng-if="config.healthCheckerDraft.type=='HTTP'")
								span.child-name 允许返回值
								span.child-txt  200-400(不包含400)
		tab(heading="网络/访问" active="tabActive[4].active" ui-sref="deployDetail.network")
			.health-con
				ul.com-list-info(ng-form name="healthFrom" ng-class="{'need-valid':healthNeedValid}")
					li
						span.info-name.not-align-input 网络模式
						.info-content
							span.small-info {{showdeploy.networkMode=='HOST'?'Host':'Overlay'}}
					li
						span.info-name.not-align-input 访问设置
						.info-content
							span.small-info {{showdeploy.visitSet}}
							//- span(ng-bind="showdeploy.loadBalanceDrafts")
							div(ng-if="showdeploy.networkMode=='DEFAULT'")
								div(ng-if="showdeploy.loadBalanceDrafts.length!==0")
									div.log-item(ng-repeat="loadbalance in showdeploy.loadBalanceDrafts")
										.line-full
											span.log-title.not-align-input 服务监听端口
											span(ng-bind="loadbalance.targetPort")
										.line-full
											span.log-title.not-align-input  对外访问端口
											span(ng-bind="loadbalance.port")
										.line-full
											span.log-title.not-align-input  对外访问IP
											.line-element
												div.ips(ng-repeat="ips in showdeploy.loadBalanceDrafts[$index].externalIPs" ng-bind="ips" ng-if="!last")
								div(ng-if="showdeploy.innerServiceDrafts.length!==0")
									div.log-item(ng-repeat="innerService in showdeploy.innerServiceDrafts")
										.line-full
											span.log-title.not-align-input 服务监听端口
											span(ng-bind="innerService.targetPort")
										.line-full
											span.log-title.not-align-input  集群内访问端口
											span(ng-bind="innerService.port")
							div(ng-if="showdeploy.networkMode=='HOST'&&showdeploy.exposePortNum!==0")
								div.log-item
									.line-full
										span 对外暴露端口个数:&nbsp;
										span(ng-bind="showdeploy.exposePortNum")
									span.txt-prompt.tool-align-input Host网络下，系统会给每个实例分配若干个端口，用于对外服务和实例间通信。此外，在Host网络下，实例ip和宿主机ip一致。
					li
						span.info-name.not-align-input 内网域名
						.info-content
							span.small-info {{showdeploy.serviceDnsName}}
		tab(heading="部署成员" active="tabActive[5].active" ng-hide="!hasMemberPermisson" ui-sref="deployDetail.user")
			div.tab-member(ng-include="'index/tpl/tplUserList/tplUserList.html'")
script(type="text/ng-template" id="versionListModal.html")
	.d-modal-header 选择版本
	form.modal-body(name="versionFrom" ng-class="{'need-valid':needValid}")
		ul.modal-item
			li
				span.modal-label 选择Version
				.com-select-con.modal-info(select-con)
					button.ui-btn.ui-btn-white.ui-btn-select
						i.icon-down
						| {{versionData.versionId?'version'+versionData.versionId:'选择Version'}}
					ul.select-list
						li.select-item(ng-repeat="version in versionList")
								a(ng-click="checkVersion(version.version)" ng-cloak) version{{version.version}}
					input(type="hidden" ng-model="versionData.versionId" name="currentVersionId" required)
					.txt-error(ng-if="needValid&&versionFrom.currentVersionId.$invalid") 请选择版本
			li(ng-if="!stateful")
				.modal-label 启动实例个数
				.modal-info
					input.ui-input-white(ng-model="versionData.replicas" name="replicas" required ng-pattern="/^[1-9]\\d*$/" )
	.modal-footer
		button.ui-btn.ui-btn-primary.ui-btn-sm(ng-click="needValid=true;versionFrom.$valid&&submit()") 确定
script(type="text/ng-template" id="scaleModal.html")
	.d-modal-header 扩容/缩容
	.modal-body.text-center.modal-scale
		ul(ng-form role="form" name="replicasForm" ng-class="{'need-valid':needValid}")
			li
				span.info-name 实例个数
				span.info-content
					input.ui-input-white(ng-model="replicas" name="replicas" required ng-pattern="/^[1-9]\\d*$/" not-equal="oldReplicas")
					| 个
					span.txt-error(ng-if="(needValid||replicasForm.replicas.$dirty)&&replicasForm.replicas.$error.pattern") 必须为大于0的整数
					span.txt-error(ng-if="(needValid||replicasForm.replicas.$dirty)&&!replicasForm.replicas.$error.pattern&&replicasForm.replicas.$error.notEqual") 不能为当前实例个数
	.modal-footer
		button.ui-btn.ui-btn-bright.ui-btn-sm.pull-right(ng-click="needValid=true;replicasForm.$valid&&submitScale()") 确定